home *** CD-ROM | disk | FTP | other *** search
- unit %A;
-
- %H{ Version %J }
-
- %Binterface
-
- %I%Gtype
-
- { Forward declarations }
- %C
-
- implementation
-
- %D
- end.
- |%N%A %B = class(TOleControl)
- private
- %C FIntf: %O;
- %D protected
- procedure InitControlData; override;
- procedure InitControlInterface(const Obj: IUnknown); override;
- public
- %E property ControlInterface: %O read FIntf;
- %F published
- %H%I%J end;
-
- |procedure %B.InitControlData;
- const
- %Kbegin
- ControlData := @CControlData;
- end;
-
- procedure %B.InitControlInterface(const Obj: IUnknown);
- begin
- FIntf := Obj as %O;
- end;
-
- %L%M
- |%A %I.%B%C%D;
- begin
- %JControlInterface.%B%K;
- end;
-
- |function %I.Get_%B%L%D;
- begin
- Result := ControlInterface.%B%K;
- end;
-
- |procedure %I.Set_%B%M;
- begin
- ControlInterface.%B%K := Value;
- end;
-
- |procedure Register;
- begin
- RegisterComponents('%E', [%F]);
- RegisterNonActiveX([%F]);
- end;
- |%N %P = %O;
-
- Co%P = class
- class function Create: %O;
- class function CreateRemote(const MachineName: string): %O;
- end;
-
- |class function Co%P.Create: %O;
- begin
- Result := CreateComObject(Class_%P) as %O;
- end;
-
- class function Co%P.CreateRemote(const MachineName: string): %O;
- begin
- Result := CreateRemoteComObject(MachineName, Class_%P) as %O;
- end;
-
- |
-
-